﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Input;
using IMeem.ViewModels;

namespace IMeem.Commands
{
    public class PreviousResultsCommand : ICommand
    {
        IMeemViewModel _iMeemViewModel;

        public PreviousResultsCommand(IMeemViewModel iMeemViewModel)
        {
            _iMeemViewModel = iMeemViewModel;
        }

        #region ICommand Members

        public bool CanExecute(object parameter)
        {
            return true;
        }

        public event EventHandler CanExecuteChanged;

        public void Execute(object parameter)
        {
            _iMeemViewModel.PreviousResults();
        }

        #endregion
    }
}
